package cn.xfdzx.android.apps.shop.contract;

import cn.xfdzx.android.apps.shop.base.BaseView;
import cn.xfdzx.android.apps.shop.bean.BaseObjectBean;
import cn.xfdzx.android.apps.shop.bean.CategoryAllBeen;
import cn.xfdzx.android.apps.shop.bean.ListingToPayBeen;
import cn.xfdzx.android.apps.shop.bean.PurchaseSubmitBeen;
import cn.xfdzx.android.apps.shop.bean.PurchaseSubmitEditBeen;
import io.reactivex.Flowable;


/**
 * @author azheng
 * @date 2018/6/4.
 * Description：
 */

public interface ListingToPayContract {
    interface Model {
        Flowable<ListingToPayBeen> initData(String pay_status);

        Flowable<PurchaseSubmitBeen> purchaseEdit(PurchaseSubmitEditBeen body);
        Flowable<BaseObjectBean> purchaseDelete(String purchase_sn);

    }

    interface View extends BaseView {
        @Override
        void showLoading();

        @Override
        void hideLoading();

        @Override
        void onError(Throwable throwable);

        void onInitSuccess(ListingToPayBeen bean);

        void onPurchaseEditSuccess(PurchaseSubmitBeen bean,int position);
        void onPurchaseDeleteSuccess(BaseObjectBean bean,int position);
    }

    interface Presenter {
        /**

         */
        void initData(String pay_status);


        void purchaseEdit(PurchaseSubmitEditBeen body,int position);
        void purchaseDelete(String purchase_sn,int position);

    }
}
